home *** CD-ROM | disk | FTP | other *** search
/ Multimedia Jumpstart / Multimedia Microsoft Jumpstart Version 1.1a (Microsoft).BIN / develpmt / source / dialogs / dialogs.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-06-02  |  4.6 KB  |  164 lines

  1. /*
  2.  * DIALOGS.H
  3.  *
  4.  * Menu identifiers, control identifiers, global variables, and function
  5.  * prototypes for the Common Dialogs sample.
  6.  *
  7.  * Copyright (c)1992 Microsoft Corporation, All Right Reserved
  8.  *
  9.  * Kraig Brockschmidt, Software Design Engineer
  10.  * Microsoft Systems Developer Relations
  11.  * One Microsoft Way
  12.  * Redmond, WA  98052
  13.  *
  14.  * Internet  :  kraigb@microsoft.com
  15.  * Compuserve:  70750,2344
  16.  * Fax       :  (206)936-7329
  17.  */
  18.  
  19.  
  20. //Resource identifiers
  21. #define IDD_FILEOPEN                        1
  22. #define IDD_SELECTFONTFLAGS                 2
  23. #define IDD_ABOUT                           3
  24.  
  25. #define IDR_MENU                            1
  26.  
  27.  
  28. //Stringtable
  29. #define IDS_DEFEXT                          0
  30. #define IDS_FILTERS                         1
  31. #define IDS_CUSTOMFILTER                    2
  32.  
  33.  
  34. //Control identifiers
  35. #define ID_NULL                             -1
  36. #define ID_ANSIONLY                         3
  37. #define ID_FIXEDPITCHONLY                   4
  38. #define ID_NOVECTORFONTS                    5
  39. #define ID_NOSIMULATIONS                    6
  40. #define ID_SCALABLEONLY                     7
  41. #define ID_TTONLY                           8
  42. #define ID_WYSIWYG                          9
  43. #define ID_PRINTERFONTS                     10
  44. #define ID_SCREENFONTS                      11
  45. #define ID_BOTH                             12
  46.  
  47.  
  48. //Menu commands
  49. #define IDM_EXIT                             99
  50.  
  51. #define IDM_COLORMIN                        100
  52. #define IDM_COLORABSOLUTEMINIMUM            100
  53. #define IDM_COLORBASIC                      101
  54. #define IDM_COLORFULLYOPEN                  102
  55. #define IDM_COLORPREVENTOPEN                103
  56. #define IDM_COLORHOOKED                     104
  57. #define IDM_COLORCUSTOMIZEDTEMPLATE         105
  58. #define IDM_COLORCUSTOMIZEDUSINGHANDLE      106
  59. #define IDM_COLORMAX                        106
  60.  
  61. #define IDM_FONTSELECTFLAGS                 200
  62. #define IDM_FONTMIN                         201
  63. #define IDM_FONTBASIC                       201
  64. #define IDM_FONTEFFECTS                     202
  65. #define IDM_FONTHOOKEDHIDECOLOR             203
  66. #define IDM_FONTMODELESS                    204
  67. #define IDM_FONTMAX                         204
  68.  
  69. #define IDM_FILEMIN                         300
  70. #define IDM_FILEFUNCTIONALOPEN              300
  71. #define IDM_FILEFUNCTIONALSAVEAS            301
  72. #define IDM_FILECUSTOMFILTER                302
  73. #define IDM_FILEEXTRAINITIALVALUES          303
  74. #define IDM_FILEMAX                         303
  75.  
  76. #define IDM_PRINTMIN                        400
  77. #define IDM_PRINTPRINT                      400
  78. #define IDM_PRINTPRINTERSETUP               401
  79. #define IDM_PRINTMAX                        401
  80.  
  81. #define IDM_SEARCHMIN                       500
  82. #define IDM_SEARCHFIND                      500
  83. #define IDM_SEARCHREPLACE                   501
  84. #define IDM_SEARCHMAX                       501
  85.  
  86. #define IDM_HELPABOUT                       600
  87.  
  88.  
  89.  
  90. /*
  91.  * Typedefs
  92.  */
  93.  
  94. //Function type of hook procedures used to avoid typecast warnings (MSC v7)
  95. typedef UINT (CALLBACK *DLGHOOKPROC)(HWND, UINT, WPARAM, LPARAM);
  96.  
  97.  
  98.  
  99. /*
  100.  * External variables
  101.  */
  102.  
  103. //DIALOGS.C
  104. extern HWND         hgWnd;
  105. extern HANDLE       hgInst;
  106. extern UINT         iMSGShareViolation;
  107. extern UINT         iMSGFileOK;
  108. extern UINT         iMSGHelp;
  109. extern UINT         iMSGListboxChange;
  110. extern UINT         iMSGColorOK;
  111. extern UINT         iMSGSetRGB;
  112. extern UINT         iMSGFind;
  113.  
  114.  
  115. //FONT.C
  116. extern HANDLE       hgFont;
  117. extern COLORREF     crgFont;
  118. extern DWORD        dwFlags;
  119.  
  120.  
  121. //SEARCH.C
  122. extern HWND         hDlgFind;
  123. extern HWND         hDlgReplace;
  124.  
  125.  
  126.  
  127. /*
  128.  * Private Messages
  129.  */
  130. #define USER_CHANGECOLOR    WM_USER+1
  131.  
  132.  
  133.  
  134. /*
  135.  * Function prototypes
  136.  */
  137.  
  138. //DIALOGS.C
  139. LONG     FAR PASCAL DialogsWndProc(HWND, UINT, UINT, LONG);
  140. BOOL     FAR PASCAL SelectFontFlagsProc(HWND, UINT, UINT, LONG);
  141. LONG     FAR PASCAL PopupWndProc(HWND, UINT, UINT, LONG);
  142. BOOL     FAR PASCAL AboutProc(HWND, UINT, UINT, LONG);
  143.  
  144. //COLOR.C
  145. COLORREF     PASCAL ColorDialogs(HWND, WORD);
  146. UINT     FAR PASCAL ColorHook(HWND, UINT, UINT, LONG);
  147. UINT     FAR PASCAL ColorModelessHook(HWND, UINT, UINT, LONG);
  148.  
  149. //FILE.C
  150. int      FAR PASCAL ReplaceCharWithNull(LPSTR, int);
  151. BOOL         PASCAL FileDialogs(HWND, WORD);
  152. UINT     FAR PASCAL FileHook(HWND, UINT, UINT, LONG);
  153.  
  154. //FONT.C
  155. BOOL         PASCAL FontDialogs(HWND, WORD, DWORD);
  156. UINT     FAR PASCAL FontHook(HWND, UINT, UINT, LONG);
  157.  
  158. //PRINT.C
  159. BOOL         PASCAL PrintDialogs(HWND, WORD);
  160.  
  161. //SEARCH.C
  162. LONG         PASCAL LSearchMessageHandler(HWND, LPFINDREPLACE);
  163. HWND         PASCAL SearchDialogs(HWND, WORD);
  164.